package com.nm.web.controller;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.servlet.ModelAndView;

/**
 * Created by alongSelf on 2017/2/7.
 */
@Controller
@RequestMapping(path = "", method = RequestMethod.GET)
public class LayoutController {
    /**
     * 获取头部jsp
     * @return
     */
    @RequestMapping(path = "/north")
    public ModelAndView north(){
        ModelAndView model =  new ModelAndView();
        model.setViewName("/admin/layout/north");
        return model;
    }

    /**
     * 获取底部jsp
     * @return
     */
    @RequestMapping(path = "/south")
    public ModelAndView south(){
        ModelAndView model =  new ModelAndView();
        model.setViewName("/admin/layout/south");
        return model;
    }

    /**
     * 获取左边jsp
     * @return
     */
    @RequestMapping(path = "west")
    public ModelAndView west(){
        ModelAndView model =  new ModelAndView();
        model.setViewName("/admin/layout/west");
        return model;
    }

    @RequestMapping(path = "welcome")
    public ModelAndView welcome(){
        ModelAndView model = new ModelAndView();
        model.setViewName("/admin/welcome");
        return model;
    }
}
